cmake_minimum_required(VERSION 3.16)

project(app)

find_package(OpenCV REQUIRED)

include_directories(
  ${PROJECT_SOURCE_DIR}/include
  ${PROJECT_SOURCE_DIR}/include/frame_parser
  ${PROJECT_SOURCE_DIR}/src/base
  /home/ubuntu/workplace/FFmpeg/build/include
)

LINK_DIRECTORIES(
	#/root/zjx/ffmpeg/build/lib
  /home/ubuntu/workplace/FFmpeg/build/lib/
)

LINK_LIBRARIES(
  ${OpenCV_LIBS} 
	avformat
	avcodec
	avutil
	m
	z
	#swresample
	pthread
)

file(GLOB_RECURSE SOURCE_FILE ${PROJECT_SOURCE_DIR}/src/*.cpp ${PROJECT_SOURCE_DIR}/src/*.c)
# aux_source_directory(${PROJECT_SOURCE_DIR}/src SOURCE_FILE)

message(STATUS ${SOURCE_FILE})

add_executable(app ${SOURCE_FILE})